cmake_minimum_required(VERSION 3.20)
project(CppMaster LANGUAGES CXX)

# Use C++11
set(CMAKE_CXX_STANDARD 11)
# Require (at least) it
set(CMAKE_CXX_STANDARD_REQUIRED ON)
# Don't use e.g. GNU extension (like -st d=gnu++11) for portability
set(CMAKE_CXX_EXTENSIONS OFF)
# Complier args
set(CMAKE_BUILD_TYPE "Debug")
if (${CMAKE_CXX_COMPILER_ID} STREQUAL MSVC)
  set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /utf-8 /W3 /WX")
elseif(${CMAKE_CXX_COMPILER_ID} STREQUAL Clang)
  set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Werror")
elseif(${CMAKE_CXX_COMPILER_ID} STREQUAL GNU)
  set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Werror")
endif()
# Root path
set(PROJECT_ROOT_DIR ${CMAKE_CURRENT_LIST_DIR})




# 简单模仿标准库 , 含有 容器类相关作业 array list string
add_subdirectory(TingSTL)
# RingBuffer
add_subdirectory(RingBuffer)
# StackInfo
add_subdirectory(StackInfo)
# 跳表
add_subdirectory(SkipList)
# 八叉树
add_subdirectory(Octree)
# 作业测试目录
add_subdirectory(Tests Tests)
